<template>
  <div class="about">
    <h1>{{ msg }}</h1>
    <button @click="mockLogin()">试试</button>
  </div>
</template>

<script>
import { getLogin } from "./api/requestMock.js";
export default {
  name: "about",
  data() {
    return {
      msg: "模拟前后台交互----返回简单登录信息",
      Login: getLogin,
    };
  },
  methods: {
    mockLogin() {
      this.Login()
        .then((res) => {
          console.log("GET模拟数据", res);
        })
        .catch((e) => {
          console.log("错误", e);
        });
    },
  },
};
</script>

<style lang="less"></style>
